import {getData, sendData} from "./http";

//添加需求
export const addDemands = (data) =>sendData('/webserver/demands/addDemands', data);

//个人需求
export const selectDemandsByUserId = (data) =>sendData('/webserver/demands/selectDemandsByUserId', data);

//用户需求
export const selectDemands = (data) =>sendData('/webserver/demands/selectAllDemands', data);

//需求详情
export const selectDemandById = (data) =>sendData(`/webserver/demands/selectDemandById`, data);

//搜索需求
export const searchDemandsByKeyword = (searchText) =>sendData(`/webserver/demands/searchDemandsByKeyword?searchText=${searchText}`);

//分类查询需求
export const searchDemandByCategory = (data) => sendData(`/webserver/demands/searchDemandByCategory`, data);

export const deleteDemandById = (data) => sendData(`/webserver/demands/deleteDemandById`, data);
